// 公共接口
import globalConfig from "@/utils/config.js";
import { request } from "@/utils/http.js";

const baseUrl = globalConfig.microUrl;
const modules = "/subscribe";
export default {
  // 订阅接口
  message: (data) => {
    return request({
      url: `${baseUrl}${modules}/message`,
      method: "POST",
      data
    });
  },
  // 校验是否需要订阅
  check: (data) => {
    return request({
      url: `${baseUrl}${modules}/check`,
      method: "GET",
      data
    });
  },
  // 是否授权校验
  appletAuthorization: (data) => {
    return request({
      url: `${baseUrl}${modules}/appletAuthorization`,
      method: "POST",
      data
    });
  }
};
